HDDS-14894. Fix Latent S3 API Issue having No Acl Check for ListMultipartUploads#9971
HDDS-14894. Fix Latent S3 API Issue having No Acl Check for ListMultipartUploads#9971fmorg-git wants to merge 3 commits intoapache:masterfrom
Conversation
618decd to
13c2f2f
Compare
|
This PR has been marked as stale due to 21 days of inactivity. Please comment or remove the stale label to keep it open. Otherwise, it will be automatically closed in 7 days. |
|
commenting to remove stale label |
|
hi @ChenSammi - this PR has been rebased and is ready for review. Thanks! |
| try { | ||
| OmMultipartUploadList omMultipartUploadList = keyManager.listMultipartUploads(bucket.realVolume(), | ||
| bucket.realBucket(), prefix, keyMarker, uploadIdMarker, maxUploads, withPagination); | ||
| if (getAclsEnabled() && isStsS3Request()) { |
There was a problem hiding this comment.
Is this ACL check is also required for normal s3 request?
There was a problem hiding this comment.
yes, discussed with others and they agreed (initially I was concerned it would break existing users, but this check needs to be there in any case)
There was a problem hiding this comment.
@fmorg-git , since it's a general fix, could you resubmit for master branch, instead of sts branch?
| * Returns true if the current RPC handler thread is processing an S3 request | ||
| * authenticated via STS temporary credentials. | ||
| */ | ||
| public static boolean isStsS3Request() { |
There was a problem hiding this comment.
This is not used, can be removed.
Conflicts: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java
Conflicts: hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java
ChenSammi
left a comment
There was a problem hiding this comment.
Looks good to me. Thanks @fmorg-git .
Please describe your PR in detail:
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-14894
How was this patch tested?
unit tests, smoke tests